package com.netflexitysolutions.amazonws.s3;

import java.util.List;

import com.amazonaws.s3.doc._2006_03_01.AmazonS3;


public interface S3 {
	
	/**
	 * @return
	 * @throws S3Exception
	 */
	public abstract List<S3Bucket> listAllMyBuckets() throws S3Exception;

    public abstract S3Bucket listBucket(String bucket) throws S3Exception;
    public abstract S3Bucket listBucket(String bucket, String prefix, String marker, String delimiter, int maxKeys) throws S3Exception;

    public S3Bucket createBucket(String bucket) throws S3Exception;
    public S3Bucket createBucket(String bucket, List<S3Grant> acl) throws S3Exception;

    public S3ServerResponseStatus deleteBucket(String bucket) throws S3Exception;

    public S3AccessControlPolicy getBucketAccessControlPolicy(String bucket) throws S3Exception;
    public S3ServerResponseStatus setBucketAccessControlPolicy(String bucket, List<S3Grant> acl) throws S3Exception;

    public S3LoggingSettings getBucketLoggingStatusOperation(String bucket) throws S3Exception;
    public void setBucketLoggingStatusOperation(String bucket, S3LoggingSettings loggingSettings) throws S3Exception;

    public S3ServerResponse putObject(S3Object object, String bucket) throws S3Exception;
    public S3ServerResponse putObjectInline(S3Object object, String bucket) throws S3Exception;

    public S3GetObjectResponse getObject(String bucket, String key, boolean loadMetadata, boolean loadData, boolean inlineData) throws S3Exception;

    public S3ServerResponseStatus deleteObject(String bucket, String key) throws S3Exception;
    public S3AccessControlPolicy getObjectAccessControlPolicy(String bucket, String key) throws S3Exception;
    public S3ServerResponseStatus setObjectAccessControlPolicy(String bucket, String key, List<S3Grant> acl) throws S3Exception;

	/**
	 * @return the accessKey
	 */
	public abstract String getAccessKey();

	/**
	 * @return the secretKey
	 */
	public abstract String getSecretKey();

	/**
	 * @return the service
	 */
	public abstract AmazonS3 getService();
}